package net.towee.model.account;

import java.util.List;

import com.google.gwt.user.client.rpc.IsSerializable;

/**
 * Rules of user privacy. Used for hidding profile information
 * from some group of users.
 * @author c58
 *
 */
public interface PrivacyRulesContainer extends IsSerializable {
	/**
	 * Add new privacy rule
	 * @param rule
	 */
	void addPrivacyRule(PrivacyRule rule);
	
	/**
	 * Delete some privacy rule
	 * @param rule
	 */
	void deletePrivacyRule(PrivacyRule rule);
	
	/**
	 * @return list of all rules
	 */
	List<PrivacyRule> getRulesList();
	
	/**
	 * Separated rule for search
	 * @return
	 */
	PrivacyRule getRuleForSearch();
	
	/**
	 * Set new rule for search
	 * @param rule
	 */
	void setRuleForSearch(PrivacyRule rule);
}
